package georah.map
{

	import flash.events.Event;
	import flash.events.MouseEvent;
	import flash.geom.Point;
	
	import georah.carto.geometries.OGCPoint;

	/**
	 * 
	 * @author yuanm
	 */
	public final class MapMouseEvent extends Event
	{
		public static const CLICK:String="mapClick";
		
		public static const CLICKS_PROGRESS:String="mapClicksProgress";
		
		public static const CLICKS_START:String="mapClicksStart";
		
		public static const CLICKS_STOP:String="mapClicksStop";
		
		public static const CLICKS_UPDATE:String="mapClicksUpdate";
		
		public static const DOUBLE_CLICK:String="mapDoubleClick";

		public static const DRAG_PROGRESS:String="mapDragProgress";
		
		public static const DRAG_START:String="mapDragStart";

		public static const DRAG_STOP:String="mapDragStop";
		
		public static const MOUSE_MOVE:String="mapMouseMove";
		
		public static const MOUSE_WHEEL:String="mapMouseWheel";
		
		public function MapMouseEvent(type:String, pixel_:Point, where_:OGCPoint, count_:int, raw_:MouseEvent, bubbles:Boolean=false, cancelable:Boolean=false)
		{
			super(type, bubbles, cancelable);

			_pixel=pixel_;
			_where=where_;
			_count=count_;
			_raw=raw_;
		}
		
		private var _count:int=0;
				
		private var _pixel:Point=null;
		
		private var _raw:MouseEvent=null;
		
		private var _where:OGCPoint=null;
		
		public function count():int
		{
			return _count;
		}
		
		public function get pixel():Point
		{
			return _pixel;
		}
		
		public function get rawMouseEvent():MouseEvent
		{
			return _raw;
		}
		
		public function get where():OGCPoint
		{
			return _where;
		}
		
	}
}
